<%
Response.Cache.SetCacheability(System.Web.HttpCacheability.NoCache);
%>
<%@ Import Namespace="Muki.Util" %>
<script Language="C#" runat="server">
void Page_Load(Object sender , EventArgs e)
{
	string cAPP_PATH=Request.ServerVariables["APPL_PHYSICAL_PATH"]+"temp\\";
	
	string XFileName=ZZGeneral.XRequest("XFileName");
	string XDELETE=ZZGeneral.XRequest("XDELETE");
	
	HttpResponse objResponse = HttpContext.Current.Response; 
	objResponse.Clear();
	objResponse.WriteFile(cAPP_PATH + XFileName);
	string xHttpHeader="attachment;filename="+XFileName;
	objResponse.AppendHeader("Content-Disposition", xHttpHeader);
	objResponse.Flush();
	
	if (XDELETE=="Y")
	{
	    System.IO.File.Delete(cAPP_PATH + XFileName);
	}

	objResponse.End();
}
</script>